package com.ruoyi.contarctbill.mapper;

import java.util.Date;
import java.util.List;

import com.ruoyi.common.annotation.RateLimiter;
import com.ruoyi.contarctbill.domain.HouseContarctBill;
import org.apache.ibatis.annotations.Param;

/**
 * 账单Mapper接口
 * 
 * @author hct
 * @date 2022-02-16
 */
public interface HouseContarctBillMapper 
{
    /**
     * 查询账单
     * 
     * @param id 账单主键
     * @return 账单
     */
    public HouseContarctBill selectHouseContarctBillById(Long id);

    /**
     * 查询账单列表
     * 
     * @param houseContarctBill 账单
     * @return 账单集合
     */
    public List<HouseContarctBill> selectHouseContarctBillList(HouseContarctBill houseContarctBill);

    /**
     * 新增账单
     * 
     * @param houseContarctBill 账单
     * @return 结果
     */
    public int insertHouseContarctBill(HouseContarctBill houseContarctBill);

    /**
     * 修改账单
     * 
     * @param houseContarctBill 账单
     * @return 结果
     */
    public int updateHouseContarctBill(HouseContarctBill houseContarctBill);

    /**
     * 删除账单
     * 
     * @param id 账单主键
     * @return 结果
     */
    public int deleteHouseContarctBillById(Long id);

    /**
     * 批量删除账单
     * 
     * @param ids 需要删除的数据主键集合
     * @return 结果
     */
    public int deleteHouseContarctBillByIds(Long[] ids);

    /** 自增加 */
    public HouseContarctBill getCurrMonthContarctBill(@Param("now") Date now);

    /** 根据 */
    public List<HouseContarctBill> selectBillById(@Param("ids") Long[] ids,@Param("startTime") Date startTime,@Param("endTime") Date endTime);

    /**
     * 批量新增固定账单
     * @param billList
     * @return
     */
    public int insertBillList(@Param("billList") List<HouseContarctBill> billList);

    /**
     * 获取最大主键用于 批量添加
     * @return
     */
    public HouseContarctBill getLastId();


    public int updateBillForRF(@Param("bill") HouseContarctBill bill, @Param("ids") List<Long> ids);
    public List<HouseContarctBill> selectHouseContarctBillListBy(HouseContarctBill houseContarctBill);

}



